#include "mainwindow.h"
#include "ui_mainwindow.h"
#include<QtGlobal>
#include<QTime>
#include<QDebug>


MainWindow::MainWindow(QWidget *parent) :
    QMainWindow(parent),
    ui(new Ui::MainWindow)
{
    ui->setupUi(this);
    resize(800,600);
}

MainWindow::~MainWindow()
{
    delete ui;
}

void MainWindow::on_pushButton_clicked()
{
    qsrand(QTime(0,0,0).secsTo(QTime::currentTime()));
    int test=qrand()%29;

   switch(test)
   {
   case 1:
                  ui->label_2->setText("PangTianao");break;
   case 2:
                  ui->label_2->setText("YuanJingrui"); break;
   case 3:
                  ui->label_2->setText("ZhuHaiwen"); break;
   case 4:
                  ui->label_2->setText("Baiyaru"); break;
   case 5:
                  ui->label_2->setText("ZhangYushuo"); break;
   case 6:
                  ui->label_2->setText("CuiZiwen"); break;
   case 7:
                  ui->label_2->setText("ZhangKaiwen"); break;
   case 8:
                  ui->label_2->setText("WuJiahao"); break;
   case 9:
                  ui->label_2->setText("LiXiang"); break;
   case 10:
                  ui->label_2->setText("GuoYujie"); break;
   case 11:
                  ui->label_2->setText("Duxin"); break;
   case 12:
                  ui->label_2->setText("DuYixing"); break;
   case 13:
                  ui->label_2->setText("WangJianxing"); break;
   case 14:
                  ui->label_2->setText("ChenJiahui"); break;
   case 15:
                  ui->label_2->setText("LiuHuiwen"); break;
   case 16:
                  ui->label_2->setText("HuangJunpeng"); break;
   case 17:
                  ui->label_2->setText("WuDongqiao"); break;
   case 18:
                  ui->label_2->setText("ZhuZiyang"); break;
   case 19:
                  ui->label_2->setText("LiuXinyuan"); break;
   case 20:
                  ui->label_2->setText("ZhuZixuan"); break;
   case 21:
                  ui->label_2->setText("LiuYawen"); break;
   case 22:
                  ui->label_2->setText("ZhuXiayang"); break;
   case 23:
                  ui->label_2->setText("ZhangYiming"); break;
   case 24:
                  ui->label_2->setText("DuYipeng"); break;
   case 25:
                  ui->label_2->setText("LiXingyi"); break;
   case 26:
                  ui->label_2->setText("LiuSongzhuo"); break;
   case 27:
                  ui->label_2->setText("ChenGuanxiu"); break;
   case 28:
                  ui->label_2->setText("SongXianfeng"); break;
   case 29:
                  ui->label_2->setText("TangHu"); break;
   case 0:
                  ui->label_2->setText("WangYikun"); break;



   }



}
